show_game_window

This function displays the main window of your game on the user's screen.

bool show_game_window(string title)

Parameters:
title
The title of the window.

Return value:
true on success, false on failure.

Remarks:
Until this function is called your game window will be invisible, thus not allowing the user to set focus to it. This in turn means that you will not be able to accept keyboard input before you call this function, and so you will usually want to do this at the very beginning of your script.

It is perfectly legal to call this function more than once during the course of your game's execution, should you wish to change the title of the window at any given time.

Example:
// Display the window and wait for the user to close it.

void main()
{
show_game_window("Another Appalling Alien Attack");
while(true)
{
if((key_down(KEY_LMENU))&&(key_pressed(KEY_F4)))
{
exit();
}
wait(5);
}
}